package net.majodali.glasshouse;

import java.util.ArrayList;
import java.util.Collection;
import java.util.List;

/**
 * 
 * @author majodali
 */
abstract public class Rule {
	ResourceMatcher inputMatcher;
	Collection<ResourceMatcher> referenceMatchers;
	Collection<TargetName> targetNames;
	
	public ResourceMatcher getInputMatcher() {
		return inputMatcher;
	}
	
	public Collection<String> getOutputResources(Resource input) {
		List<String> targets = new ArrayList<String>();
		
		for (TargetName tn : targetNames)
			targets.add(tn.getTargetName(input));
		return targets;
	}
}
